package com.maimao.search.controller;

import com.maimao.core.model.resp.Result;
import com.maimao.search.controller.base.BaseController;
import com.maimao.search.service.DocService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author MaoLin Wang
 * @date 2020/12/27 6:18 下午
 */
@RequestMapping("/searchMS")
@RestController
public class GoodsMsController extends BaseController {
    @Autowired
    private DocService docService;

    @GetMapping("/refresh")
    public Result<String> refreshGoodsDoc() {
        docService.createGoodsDoc();
        return Result.ok();
    }
}
